<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ include file="/head/common/include/page.jsp"%>
<jsp:useBean id="pojo" class="com.wang.users.pojo.ABodyStand"/>
<c:set value="${requestScope.usersResponse.data.one }" var="one"/>
<c:set value="${requestScope.classResponse.data.list }" var="list"/>
<!DOCTYPE html>
<html lang="zh-CN">
	<head>
		<title>修改体侧标准信息 - 体能测试系统</title>
		<%@ include file="/head/common/include/title.jsp"%>
	    <link rel="stylesheet" href="${rootPath }/head/common/resource/bootstrapvalidator/css/form-validation.css" rel="stylesheet">
	  	<script type="text/javascript" src="${rootPath }/head/common/resource/bootstrapvalidator/js/form-validation.js"></script>
	  	
	  	<script language="javascript" type="text/javascript" src="${rootPath }/common/resource/My97DatePicker/WdatePicker.js"></script>
	  	<script type="text/javascript">
	  		$(function()
			{
			  	$("#form").FormValidation({
		  			fields:
	  				{
		  				phone:
	  					{
		  					validators: {
		  	                    notEmpty: {
		  	                        message: '手机号不能为空'
		  	                    },
		  	                    stringLength: {
		  	                        min: 11,
		  	                        max:11,
		  	                        message: '手机号的长度为在11位'
		  	                    },
		  	                    regexp: {
		  	                        regexp: /^[\d]{11}$/i,
		  	                        message: '手机号不符合规则'
		  	                    }
		  	                }
	  					},
	  					grade:
	  					{
		  					validators: {
		  	                    notEmpty: {
		  	                        message: '年级不能为空'
		  	                    },
		  	                    regexp: {
		  	                        regexp: /^[\d]+$/i,
		  	                        message: '年级不符合规则'
		  	                    }
		  	                }
	  					},
	  					age:
	  					{
		  					validators: {
		  	                    notEmpty: {
		  	                        message: '年龄不能为空'
		  	                    },
		  	                    regexp: {
		  	                        regexp: /^[\d]+$/i,
		  	                        message: '年龄不符合规则'
		  	                    }
		  	                }
	  					},
	  				}
				});
			  	
			});
	  	</script>
	</head>
	<body>
		<%@ include file="/head/common/include/header.jsp"%>
		<!-- 网页的主体 -->
		<div class="container">
			<div class="col-md-8 col-sm-10">
				<form id="form" method="post" class="form-horizontal" action="${rootPath }/head/bodys/standsUpdateSubmit">
					<input type="hidden" name="operType" value="${param.operType }">
					<h2
						class="col-sm-10 col-sm-offset-1 form-signin-heading text-center">修改体侧标准信息</h2>
					<div class="form-group row">
						<label for="inputPassword" class="col-sm-3 control-label">年级</label>
						<div class="col-sm-8">
							<input type="text" name="grade" id="grade" value="${one.grade }"
								class="form-control" placeholder="年级" />
						</div>
					</div>
					<div class="form-group row">
						<label for="inputPassword" class="col-sm-3 control-label">性别</label>
						<div class="col-sm-8">
							<c:forEach items="${pojo.enumsMap }" var="me" varStatus="stat">
								<c:if test="${fn:startsWith(me.key,'SEX')}">
									<!-- 拆分,按照-拆分,取最后一个 -->
									<c:set value="${fn:split(me.key, '-')}" var="keys"/>
									<div class="form-check form-check-inline">
										<label class="form-check-label" for="${me.key}">
											<input type="radio" name="sex" id="${me.key}" value="${keys[1] }" 
												class="form-check-input" placeholder="生日" 
												${one.sex == keys[1] ? 'checked' : '' }
											/>
										    ${me.value }
										</label>
									</div>
								</c:if>
							</c:forEach>
						</div>
					</div>
					<div class="form-group row">
						<label for="email" class="col-sm-3 control-label">肺活量</label>
						<div class="col-sm-8">
							<input type="text" name="vitalcapacity" id="vitalcapacity" value="${one.vitalcapacity }"
								class="form-control" placeholder="肺活量" />
						</div>
					</div>
					<div class="form-group row">
						<label for="email" class="col-sm-3 control-label">长跑</label>
						<div class="col-sm-8">
							<input type="text" name="longrun" id="longrun" value="${one.longrun }"
								class="form-control" placeholder="长跑" />
						</div>
					</div>
					<div class="form-group row">
						<label for="email" class="col-sm-3 control-label">短跑</label>
						<div class="col-sm-8">
							<input type="text" name="shortrun" id="shortrun" value="${one.shortrun }"
								class="form-control" placeholder="短跑" />
						</div>
					</div>
					<div class="form-group row">
						<label for="email" class="col-sm-3 control-label">身高</label>
						<div class="col-sm-8">
							<input type="text" name="height" id="height" value="${one.height }"
								class="form-control" placeholder="身高" />
						</div>
					</div>
					
					<div class="form-group row">
						<label for="email" class="col-sm-3 control-label">体重</label>
						<div class="col-sm-8">
							<input type="text" name="weight" id="weight" value="${one.weight }"
								class="form-control" placeholder="体重" />
						</div>
					</div>
					<div class="form-group row">
						<label for="email" class="col-sm-3 control-label">体脂</label>
						<div class="col-sm-8">
							<input type="text" name="bml" id="bml" value="${one.bml }"
								class="form-control" placeholder="体脂" />
						</div>
					</div>
					<div class="form-group row">
						<label for="email" class="col-sm-3 control-label">仰卧起坐/引体向上</label>
						<div class="col-sm-8">
							<input type="text" name="abdominalcurl" id="abdominalcurl" value="${one.abdominalcurl }"
								class="form-control" placeholder="仰卧起坐/引体向上" />
						</div>
					</div>
					<div class="form-group row">
						<label for="email" class="col-sm-3 control-label">坐位体前屈</label>
						<div class="col-sm-8">
							<input type="text" name="sittingforward" id="sittingforward" value="${one.sittingforward }"
								class="form-control" placeholder="坐位体前屈" />
						</div>
					</div>
					<div class="form-group row">
						<label for="inputPassword" class="col-sm-3 control-label">状态</label>
						<div class="col-sm-8">
							<c:forEach items="${pojo.enumsMap }" var="me" varStatus="stat">
								<c:if test="${fn:startsWith(me.key,'STATUS')}">
									<!-- 拆分,按照-拆分,取最后一个 -->
									<c:set value="${fn:split(me.key, '-')}" var="keys"/>
									<div class="form-check form-check-inline">
										<label class="form-check-label" for="${me.key}">
											<input type="radio" name="status" id="${me.key}" value="${keys[1] }" 
												class="form-check-input" placeholder="生日" 
												${one.status == keys[1] ? 'checked' : '' }
											/>
										    ${me.value }
										</label>
									</div>
								</c:if>
							</c:forEach>
						</div>
					</div>
					
					
					<div class="form-group">
						<div class="col-sm-8 col-sm-offset-2">
							<button class="btn btn-md btn-primary" type="submit">提交</button>
						</div>
					</div>
				</form>
			</div>
		</div>
		<%@ include file="/head/common/include/footer.jsp"%>
	</body>
</html>